<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        let math = {
            sum: function () {
                console.log(arguments);
                // console.log(arguments[0])
                // let arr1 = arguments[0]
                let max = 0
                let min = arguments[0]
                for (let i = 0; i < arguments.length; i++) {
                    if (arguments[i] > max) {
                        max = arguments[i]
                    }
                    if (arguments[i] < min) {
                        min = arguments[i]
                    }
                }
                console.log(max);
                console.log(min);
            }
        }
        // let arr = [4, 3, 5, 6, 78, 23]
        math.sum(4, 3, 5, 6, 78, 23)
    </script>
</body>

</html>